package com.java.netty.common.helper;

import com.alibaba.fastjson.JSON;
import com.java.netty.common.codec.VncPackageContent;
import com.java.netty.common.codec.VncPacket;
import com.java.netty.common.enums.ProtocolVer;
import com.java.netty.common.pptp.Pptp;

public class VncHelper {

   public static byte[] buildMsg(VncPacket vncPacket) {
      int dataLen = vncPacket.getPkgSize();
      VncPackageContent content = vncPacket.getContent();
      byte[] result = new byte[4 + dataLen + 4];
      String s = JSON.toJSONString(vncPacket);
      return s.getBytes();
   }
}